<%@ page contentType="text/html;charset=utf-8"%>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<%@ include file="admin_header.jsp"%>
<%@ include file="admin_container.jsp"%>
<img src="../images/admin/logo.jpg" />
<div id="content">
<%@ include file="admin_nav.jsp"%>
<div id="right">

<c:if test="${account == null}">
	<h1 class="topmenu">添加新用户</h1>
	<form action="<c:url value="/administrator/account.htm?method=add"/>"
		method="post">
</c:if>
<c:if test="${account != null}">
	<form action="<c:url value="/administrator/account.htm?method=edit"/>"
		method="post">
	<h1 class="topmenu">修改用户信息</h1>
	<input name="userID" type="hidden" value="${account.userID }" />
</c:if>

<dl>
<dt>用户名：</dt>
<dd><input name="userName" type="text" height="20px" value="${account.userName}"/></dd>
<dt>密码：</dt>
<dd><input name="password" type="password" height="20px" /></dd>
<dt>确认密码：</dt>
<dd><input name="repetPassword" type="password" height="20px" /></dd>
<dt>邮件地址：</dt>
<dd><input name="email" type="text" height="20px"  value="${account.email }"/></dd>
<dt>电话：</dt>
<dd><input name="phone" type="text" height="20px"  value="${account.phone }"/></dd>
<dt>省份：</dt>
<dd><input name="province" type="text" height="20px" value="${account.province}"/></dd>
<dt>地址：</dt>
<dd><input name="address" type="text" height="20px" value="${account.address}" /></dd>
<dt>注册类型：</dt>
<dd>
<select name="type">
	<c:forEach var="a" items="${authories }" varStatus="s">
		<option value="${s.count }" <c:if test="${s.count == account.type }">"selected"</c:if>>${a}</option>
	</c:forEach>
</select> 
</dd>
<dt><input name="" type="submit" id="button" value="保存用户信息" /></dt>
</dl>
</form>
</div>
</div>
<%@ include file="admin_footer.jsp"%>
